package service;

import Pojo.Schedule;
import dao.ScheduleMapper;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional
public class ScheduleServiceImpl
  implements ScheduleService
{

  @Autowired
  private ScheduleMapper scheduleMapper;

  public void insertschedule(Schedule schedule)
  {
    this.scheduleMapper.insertschedule(schedule);
  }

  public List<Schedule> selectAll()
  {
    List list = this.scheduleMapper.selectAll();
    return list;
  }

  public void deleteschedule(Integer id)
  {
    this.scheduleMapper.deleteschedule(id);
  }

  public void updateschedule(Schedule schedule)
  {
    this.scheduleMapper.updateschedule(schedule);
  }

  public Schedule selectbyid(Integer id)
  {
    Schedule schedule = this.scheduleMapper.selectbyid(id);
    return schedule;
  }
}